<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<%@taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <script type="text/javascript">
        var ctx = "${ctx}";
    </script>
    <%@ include file="/static/pages/common.jsp" %>
    <title>生成方案配置</title>
</head>
<body>
<!-- 操作按钮区 -->
<div class="search_div">
    <form id="searchForm" action="">
        <span class="search_font">业务表名称：</span>
        <input id="NAME" name="NAME" class="search_input"
               onkeypress="if(event.keyCode==13) {refreshJSXX();;return false;}"/>
        <button type="button" class="_searchbtn" onclick="refreshSCHEME();">查询</button>
        <button type="button" class="_btn" onclick="formReset('searchForm');">重置</button>
        <span class="fl_r">
<button type="button" class="_masterbtn" onclick="openAddScheme();">新增</button>
<button type="button" class="_btn" onclick="refreshSCHEME();">刷新</button>
</span>
    </form>
</div>
<!-- 表格区 -->
<table id="schemeGrid"></table>
<div id="schemePager"></div>
<!-- 机构信息 -->
<div id="schemeContent" style="display: none;background-color: #F5F6FA;">
    <div class="megbox">
        <form id="schemeForm" name="schemeForm" class="megbox_form">
            <dl class="megbox_dl">
                <dd>
                    <label>模板分类：</label>
                    <input type="hidden" id="id" name="id">
                    <%--<span class="megbox_span">
                        <input id="CATEGORY" name="CATEGORY" class="{validate:{required:true,messages:{required:'角色名称为必填项！'}}} megbox_input" type="text" style="width: 471px;">
                    </span>--%>
                    <select id="category" name="category" class=" megbox_select" style="width: 471px;margin-left: 5px">
                        <option value="curdModal">单表(弹框)</option>
                        <option value="curdPage">单表(新开页)</option>
                    </select>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>业务表名：</label>
                    <%--<span class="megbox_span">
                        <input id="GEN_TABLE_ID" name="GEN_TABLE_ID" class="{validate:{required:true,messages:{required:'角色名称为必填项！'}}} megbox_input" type="text" style="width: 471px;">
                    </span>--%>
                    <select id="gen_table_id" name="gen_table_id" class=" megbox_select" style="width: 471px;margin-left: 5px">
                        <c:forEach items="${tableList}" var="table">
                            <option value="${table.NAME}">${table.NAME}</option>
                        </c:forEach>
                    </select>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>方案名称：</label>
                    <span class="megbox_span">
                        <input id="name" name="name" value="测试方案" class="{validate:{required:true,messages:{required:'角色名称为必填项！'}}} megbox_input" type="text" style="width: 471px;">
                    </span>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>包名：</label>
                    <span class="megbox_span">
                        <input id="package_name" name="package_name" placeholder="com.qysoft.modules" value="com.qysoft.modules" class="{validate:{required:true,messages:{required:'角色名称为必填项！'}}} megbox_input" type="text" style="width: 471px;"/>
                    </span>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>模块名：</label>
                    <span class="megbox_span">
                        <input id="module_name" value="fj" name="module_name" placeholder="例如 sys" class="{validate:{required:true,messages:{required:'角色名称为必填项！'}}} megbox_input" type="text" style="width: 471px;">
                    </span>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>访问url：</label>
                    <span class="megbox_span">
                        <input id="sub_module_name" name="sub_module_name" class="megbox_input" type="hidden" style="width: 471px;">
                        <input id="url" name="url" class="megbox_input" type="text" style="width: 471px;">
                    </span>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>功能描述：</label>
                    <span class="megbox_span">
                        <input id="function_name" value="附件" name="function_name" class="megbox_input" type="text" style="width: 471px;">
                    </span>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd>
                    <label>功能作者：</label>
                    <span class="megbox_span">
                        <input id="function_author" value="zj" name="function_author" class="megbox_input" type="text" style="width: 471px;">
                    </span>
                </dd>
            </dl>
            <dl class="megbox_dl">
                <dd style="width:562px;"><p class="fl_r">
                    <button type="button" class="_masterbtn" onclick="saveSCHEME();">保存并生成代码</button>
                    <button type="button" class="_btn" onclick="qyClose();">关闭</button>
                </p></dd>
            </dl>
        </form>
    </div>
</div>
</body>
</html>